//
//  BKBtnArrView.h
//  BukaLive
//
//  Created by 曹飞 on 2017/3/31.
//  Copyright © 2017年 曹飞. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "BKButton.h"




typedef void(^BtnArrViewDidSelect)(NSInteger index,BKButton * btn);

typedef NS_ENUM(NSUInteger, BKBtnArrViewType) {
    BKBtnArrViewTypeHorizontal,
    BKBtnArrViewTypeVertical
};


@interface BKBtnArrView : UIView
@property (nonatomic,strong) NSMutableArray * btnArr;
@property (nonatomic,copy) BtnArrViewDidSelect didSelectBlock;


//初始化 ⚠️图片是资源包里的，如果用外部的图片，需要重写-(void)creatContent:(NSArray*)selectImages withUnSelectImage:(NSArray *)unSelectImages
- (instancetype)initWithSelectImage:(NSArray *)selectImages
                  withUnSelectImage:(NSArray *)unSelectImages
                          withType:(BKBtnArrViewType)toolType
                         withBlock:(BtnArrViewDidSelect)didSelect;

//
//- (instancetype)initWithSelectImage:(NSArray *)selectImages
//                  withUnSelectImage:(NSArray *)unSelectImages
//                           withType:(BKBtnArrViewType)toolType
//                          withBlock:(BtnArrViewDidSelect)didSelect;

- (instancetype)initWithSelectImageTrue:(NSArray *)selectImages
                  withUnSelectImageTrue:(NSArray *)unSelectImages
                               withType:(BKBtnArrViewType)toolType
                              withBlock:(BtnArrViewDidSelect)didSelect;

-(void)creatContentImage:(NSArray*)selectImages
       withUnSelectImage:(NSArray *)unSelectImages;




//初始化文字形式
-(instancetype)initWithNames:(NSArray*)names
           withUnSelectColor:(UIColor *)unSelectColor
             withSelectColor:(UIColor*)selectColor
                    withType:(BKBtnArrViewType)toolType
                   withBlock:(BtnArrViewDidSelect)didSelect;






-(BKButton*)getBtnIndex:(NSInteger)index;

//初始化文字形式改变颜色可以用这个方法
-(void)selectIndex:(NSInteger)index;

-(NSInteger)getCurrentIndex;

@end
